<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html>

	<head>
		<meta charset="UTF-8">
		<title>数据上报系统</title>
		<link rel="stylesheet" type="text/css" href="/report/Public/Home/css/index.css" />
		<link rel="stylesheet" href="/report/Public/Home/css/list.css" />
		<script src="/report/Public/assets/js/jquery.min.js"></script>
		<script src="/report/Public/assets/js/jquery.form.js"></script>
		<script src="/report/Public/layer/layer.js"></script>
		<script src="/report/Public/assets/js/bootstrap.js"></script>		
		<link rel="stylesheet" href="/report/Public/assets/css/bootstrap.css" />		
	</head>

	<body>

		<div class="row rowList rowHeader">
			<div class="header1">
				<span class="myIcon" style="margin-right: 5px;">&#xe626;</span>你好，<span id="userName"><?php echo $_SESSION['c_user'] ?></span>！
				<a style="color:white;text-decoration: none;" href="<?php echo U('index/loginout');?>"><span id="cancel"><span class="myIcon">&#xe611;</span>注销</span></a>
			</div>
			<div class="">
				<img style="height: 40px; margin: 10px 0;" src="/report/Public/Home/img/logo2.png" />
			</div>

		</div>
		<div class="row rowB">
			<div class="rowL">
				<ul id="state">
					<li>
						<div class="stateType">
							新报表任务
						</div>
						<ul class="list">
                            <?php if(is_array($w_table)): $i = 0; $__LIST__ = $w_table;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$v): $mod = ($i % 2 );++$i;?><li class="">
									<a style="text-decoration: none;" href="<?php echo U('index/table',array('id'=>$v['id']));?>">
										<div class="listType"><?php echo ($v["title"]); ?>(<?php echo ($v["year"]); ?>年<?php echo ($v["quarter"]); ?>季度)</div>
									</a>
                                </li><?php endforeach; endif; else: echo "" ;endif; ?>
						</ul>

					</li>
					<li>
						<div class="stateType">
							审核中
						</div>
						<ul class="list"   style="display: block;">
							<?php if(is_array($d_table)): $i = 0; $__LIST__ = $d_table;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$v): $mod = ($i % 2 );++$i;?><li class="">
									<?php if($v['id'] != $info['id']): ?><a style="text-decoration: none;" href="<?php echo U('index/d_table',array('id'=>$v['id']));?>"><?php endif; ?>
										<div class="listType"><?php echo ($v["title"]); ?>(<?php echo ($v["year"]); ?>年<?php echo ($v["quarter"]); ?>季度)</div>
										<?php if($v['id'] != $info['id']): ?></a><?php endif; ?>
								</li><?php endforeach; endif; else: echo "" ;endif; ?>
						</ul>

					</li>
					<li>
						<div class="stateType">
							未通过
						</div>
						<ul class="list">
							<?php if(is_array($n_table)): $i = 0; $__LIST__ = $n_table;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$v): $mod = ($i % 2 );++$i;?><li class="">
									<a style="text-decoration: none;" href="<?php echo U('index/n_table',array('id'=>$v['id']));?>">
										<div class="listType"><?php echo ($v["title"]); ?>(<?php echo ($v["year"]); ?>年<?php echo ($v["quarter"]); ?>季度)</div>
									</a>
								</li><?php endforeach; endif; else: echo "" ;endif; ?>
						</ul>

					</li>
					<li>
						<div class="stateType">
							已过期
						</div>
						<ul class="list">
							<?php if(is_array($e_table)): $i = 0; $__LIST__ = $e_table;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$v): $mod = ($i % 2 );++$i;?><li class="">
									<a style="text-decoration: none;" href="<?php echo U('index/e_table',array('id'=>$v['id']));?>">
										<div class="listType"><?php echo ($v["title"]); ?>(<?php echo ($v["year"]); ?>年<?php echo ($v["quarter"]); ?>季度)</div>
									</a>
								</li><?php endforeach; endif; else: echo "" ;endif; ?>
						</ul>

					</li>
					<li>
						<div class="stateType">
							历史报表
						</div>
						<ul class="list list2">
                            <?php if(is_array($y_table)): $i = 0; $__LIST__ = $y_table;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$y): $mod = ($i % 2 );++$i;?><li class="">
									<?php if($y['id'] != $info['id']): ?><a style="text-decoration: none;" href="<?php echo U('index/w_table',array('id'=>$y['id']));?>"><?php endif; ?>
										<div class="listType"><?php echo ($y["title"]); ?>(<?php echo ($y["year"]); ?>年<?php if($info['quarter'] == 1): ?>1<?php else: ?>1-<?php echo ($info['quarter']); endif; ?>季度)</div>
									<?php if($y['id'] != $info['id']): ?></a><?php endif; ?>
                                </li><?php endforeach; endif; else: echo "" ;endif; ?>
						</ul>

					</li>
				</ul>
			</div>
			<div class="rowR">

				<!--查看的上传数据-->
				<div id="showThis" style="display: block;">
					<form action="<?php echo U('table_upload');?>" method="post" id="form2">
					<div class="clearFLoat">
<!--						<input type="hidden" name="tableid" value="<?php echo ($info["id"]); ?>" >
						<button id="updata" type="submit"><span class="myIcon">&#xe613;</span>上传数据</button>
						<input type="file" style="display: inline; margin-top: 19px;float: right;" id="excel"  name="excel" />-->


					</div>
					</form>

						<div id="tableDetail">
							<div class="title">
								<div class="titltLeft">
									<h3><?php echo ($info['title']); ?>(<?php echo ($info['code']); ?>表)</h3>
								</div>

							</div>
							<div>
								<div class="unit"  style="float: left;margin-top: 80px">
									填报单位：<?php echo ($info['target']); ?>
									&nbsp;
									<span>年份季度：<?php echo ($info['year']); ?>年<?php if($info['quarter'] == 1): ?>1<?php else: ?>1-<?php echo ($info['quarter']); endif; ?>季度</span>
								</div>
								<div class="titltRight"  style="float: right;">
									<ul>
										<li>表&emsp;&emsp;号：<?php echo ($info['code']); ?>表</li>
										<li>制定机关：</li>
										<li>批准机关：</li>
										<li>批准文号：</li>
										<li>有效期至：<?php echo (date("y-m-d",$info["endtime"])); ?></li>
									</ul>
								</div>
							</div>
							<div id="table">

								<table border="1" cellspacing="0" cellpadding="0" width="100%" frame="hsides">
									<tbody>
										<tr class="level1">
											<td width="30%">指标名称</td>
											<td width="10%">计量单位</td>
											<td width="10%">代码</td>
											<td width="25%">上年<?php if($info['quarter'] == 1): ?>1<?php else: ?>1-<?php echo ($info['quarter']); endif; ?>季度</td>
											<td width="25%">本年<?php if($info['quarter'] == 1): ?>1<?php else: ?>1-<?php echo ($info['quarter']); endif; ?>季度</td>
										</tr>
										<tr class="level1">
											<td>甲</td>
											<td>乙</td>
											<td>丙</td>
											<td>1</td>
											<td>2</td>
										</tr>

										<?php if(is_array($res)): foreach($res as $key=>$v): ?><tr <?php if($v["code"] == '--'): ?>class="level1"<?php else: ?>class="level2"<?php endif; ?>>
												<td><?php echo ($v["name"]); ?></td>
												<td><?php echo ($v["metering"]); ?></td>
												<td><?php echo ($v["code"]); ?></td>
												<td><?php echo ($v["last"]); ?></td>
												<td><?php echo ($v["now"]); ?></td>
											</tr><?php endforeach; endif; ?>
									</tbody>
								</table>

							</div>
							<div class="footer">
								<p>补充说明：<span><?php echo ($info["remark"]); ?></span></p>
								<p>报送日期和方式：<span>2017年4月10日前，2,3,4季度于季后15日前，电子邮件和加盖公章的纸介质，季报</span></p>
								<p>
									<ul class="info">
										<li style="width: 25%;">
											单位负责人：<?php echo ($info["fz"]); ?>
										</li>
										<li style="width: 20%;">
											联系人：<?php echo ($info["lx"]); ?>
										</li>
										<li style="width: 20%;">
											填表人：<?php echo ($info["tb"]); ?>
										</li>
										<li style="width: 35%;">
											报出日期：<?php echo (date('Y',$info["add_time"])); ?>年<?php echo (date('m',$info["add_time"])); ?>月<?php echo (date('d',$info["add_time"])); ?>日
										</li>
									</ul>
								</p>
							</div>
						</div>


				</div>

			</div>
		</div>

		<script type="text/javascript" src="/report/Public/Home/js/list3.js"></script>
	</body>
<script>



</script>
</html>